home *** CD-ROM | disk | FTP | other *** search
- #include <stdio.h>
- #include <math.h>
- #include <string.h>
- #include <sys/file.h>
-
- #include <suntool/sunview.h>
- #include <suntool/canvas.h>
- #include <suntool/panel.h>
- #include <pixrect/pixrect_hs.h>
- #include <sunwindow/defaults.h>
-
- #define PROFILE ".alv_profile"
- #define NOT_SUPPORTED -1
- #define ROUND_DEPTH(d) ((d==1)?1:(d<=8)?8:(d<=16)?16:(d<=32)?32:NOT_SUPPORTED)
- #define MAXLEVEL(d) ((int)(pow(2.,(double)(d))))
- #define MT_GRAYSCALE 4
-
- #define ALV_ERR_DEPTH_NO_SUPPORT "Depth not supported"
-
- #ifndef MAX
- #define MAX(a,b) (((a)>(b))?(a):(b))
- #endif
- #ifndef MIN
- #define MIN(a,b) (((a)<(b))?(a):(b))
- #endif
-
- #define strsave(s) (strcpy(malloc(strlen(s)+1),s))
-
- #define FONT "/usr/lib/fonts/fixedwidthfonts/screen.r.12"
- #define SMALL_FONT "/usr/lib/fonts/fixedwidthfonts/screen.r.7"
-
- #define FALSE 0
- #ifndef TRUE
- #define TRUE !FALSE
- #endif
-
- ixfont *font, *smallfont;
-
- nt bitrestrict, verbose, mono_override;
-
- xtern char *optarg;
- xtern int optind, opterr;
-
- nt errflag;
- nt gc, stream;
- FILE *f[2];
- har *mode[2];
-
- nsigned char greylevelmap[256];
-